//
//
//
//
//
//
//

import { mapGetters } from "vuex";
import template from "./agencyRoleTemplate";
const { render, staticRenderFns } = template;

export default {
  render,
  staticRenderFns,
  data() {
    return {
      imgUrl: "",
    };
  },
  computed: {
    ...mapGetters(["userInfo"]),
  },
  created() {
    this.getAgencyRole(localStorage.getItem("token"));
  },
  methods: {
    getAgencyRole: function (token) {
      let vm = this;
      vm.$vux.loading.show({});
      vm.$http
        .get(vm.urlRequest + "?m=api&c=user&a=agentSystempc", { token: token })
        .then((res) => {
          if (res.status == 0) {
            vm.imgUrl = res.img_url;
          }
          vm.$vux.loading.hide();
        })
        .catch((err) => {
          vm.$vux.loading.hide();
          console.log(err);
        });
    },
  },
  watch: {
    $route() {
      // this.getAgencyRole();
    },
  },
};

// WEBPACK FOOTER //
// ./src/components/personalCenter/agencyShare/agencyRole.vue
